package com.gxa.ehome.pojo;

import java.io.Serializable;

public class GoodsDetail implements Serializable {
    private Integer id;
    // 一对一关联时, 在主表(商品表)中声明从表的对象(商品详情表)
    private Goods goods;  // 在一对一关联的时候, 描述商品id的位置,应当用对象类型表示
    private String desc;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Goods getGoods() {
        return goods;
    }

    public void setGoods(Goods goods) {
        this.goods = goods;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    @Override
    public String toString() {
        return "GoodsDetail{" +
                "id=" + id +
                ", goods=" + goods +
                ", desc='" + desc + '\'' +
                '}';
    }
}
